<template>
    <div class="template"> 
        <h3>示例</h3>
        <ParentChildTable_v2 v-bind="tableContent" ></ParentChildTable_v2>
        <div class="markdown-body">
            <parentChildTableMD_v2></parentChildTableMD_v2>
        </div>
    </div>
</template>
<script>
    import ParentChildTable_v2 from "../components/baseComponents/parentChildTable_v2";
    import parentChildTableMD_v2 from  "../md/parentChildTableMD_v2.md"
    export default {
        name:"parentChildTable_v2",
        components:{ParentChildTable_v2,parentChildTableMD_v2},
        data(){
            return{
               tableContent:{
                    // 父级表头数据
                    stripe:true,
                    tooltip:"dark",
                    columns:[
                        {label:"商品名称",prop:"name", },
                        {label:"所属店铺",prop:"shop"},
                        {label:"商品ID",prop:"id"},
                        {label:"店铺ID",prop:"shopId"},
                        {label:"商品分类",prop:"category"},
                        {label:"店铺地址",prop:"address"},
                        {label:"商品描述",prop:"desc"},
                    ],
                    //数据
                    children: [{
                        id: '12987122',
                        name: '好滋好味鸡蛋仔',
                        category: '江浙小吃、小吃零食',
                        desc: '荷兰优质淡奶，奶香浓而不腻',
                        address: '上海市普陀区真北路',
                        shop: '王小虎夫妻店',
                        shopId: '10333',
                        // 头部内容需要自己添加
                        stripe:true,
                        tooltip:"dark",
                        columns:[
                            {label:"商品名称",prop:"name", },
                            {label:"所属店铺",prop:"shop"},
                            {label:"商品ID",prop:"id"},
                            {label:"店铺ID",prop:"shopId"},
                            {label:"商品分类",prop:"category"},
                            {label:"店铺地址",prop:"address"},
                            {label:"商品描述",prop:"desc"},
                        ],
                        children:[{
                            id: '1298712377',
                            name: '好滋好味鸡蛋仔',
                            category: '江浙小吃、小吃零食',
                            desc: '荷兰优质淡奶，奶香浓而不腻',
                            address: '上海市普陀区真北路',
                            shop: '王小虎夫妻店',
                            shopId: '1033366',
                            // 头部内容需要自己添加
                            stripe:true,
                            tooltip:"dark",
                            columns:[
                                {label:"商品名称",prop:"name", },
                                {label:"所属店铺",prop:"shop"},
                                {label:"商品ID",prop:"id"},
                                {label:"店铺ID",prop:"shopId"},
                                {label:"商品分类",prop:"category"},
                                {label:"店铺地址",prop:"address"},
                                {label:"商品描述",prop:"desc"},
                            ],
                            children:[],
                        }]
                    }, {
                        id: '12987123',
                        name: '好滋好味鸡蛋仔',
                        category: '江浙小吃、小吃零食',
                        desc: '荷兰优质淡奶，奶香浓而不腻',
                        address: '上海市普陀区真北路',
                        shop: '王小虎夫妻店',
                        shopId: '10333',
                        // 头部内容需要自己添加
                        stripe:true,
                        tooltip:"dark",
                        columns:[
                            {label:"商品名称",prop:"name", },
                            {label:"所属店铺",prop:"shop"},
                            {label:"商品ID",prop:"id"},
                            {label:"店铺ID",prop:"shopId"},
                            {label:"商品分类",prop:"category"},
                            {label:"店铺地址",prop:"address"},
                            {label:"商品描述",prop:"desc"},
                        ],
                        children:[]
                    }, {
                        id: '12987125',
                        name: '好滋好味鸡蛋仔',
                        category: '江浙小吃、小吃零食',
                        desc: '荷兰优质淡奶，奶香浓而不腻',
                        address: '上海市普陀区真北路',
                        shop: '王小虎夫妻店',
                        shopId: '10333',
                        // 头部内容需要自己添加
                        stripe:true,
                        tooltip:"dark",
                        columns:[
                            {label:"商品名称",prop:"name", },
                            {label:"所属店铺",prop:"shop"},
                            {label:"商品ID",prop:"id"},
                            {label:"店铺ID",prop:"shopId"},
                            {label:"商品分类",prop:"category"},
                            {label:"店铺地址",prop:"address"},
                            {label:"商品描述",prop:"desc"},
                        ],
                        children:[]
                    }, {
                        id: '12987126',
                        name: '好滋好味鸡蛋仔',
                        category: '江浙小吃、小吃零食',
                        desc: '荷兰优质淡奶，奶香浓而不腻',
                        address: '上海市普陀区真北路',
                        shop: '王小虎夫妻店',
                        shopId: '10333',
                        // 头部内容需要自己添加
                        stripe:true,
                        tooltip:"dark",
                        columns:[
                            {label:"商品名称",prop:"name", },
                            {label:"所属店铺",prop:"shop"},
                            {label:"商品ID",prop:"id"},
                            {label:"店铺ID",prop:"shopId"},
                            {label:"商品分类",prop:"category"},
                            {label:"店铺地址",prop:"address"},
                            {label:"商品描述",prop:"desc"},
                        ],
                        children:[]
                    }]
                }
            }
        }
    }
</script>
